<template>
  <div>
    <div class="bg-white grid-content">
      <div style="overflow: hidden">
        <div class="mytitle">
          <svg-icon icon-class="yjbb" class="myIcon" />消防器材台账
        </div>
        <div class="myButtons">
          <el-button
            @click="handleClick('', 'add')"
            v-if="hasPermission('sys:sjtb:aqgl:xfqctz:add')"
            >新增</el-button
          >
          <el-button
            class="import-button"
            icon="el-icon-upload2"
            @click="uploadFiles"
            v-if="hasPermission('sys:sjtb:aqgl:xfqctz:import')"
          >
            <i class="icon"></i>
            批量导入
          </el-button>
          <el-dialog
            title="批量导入"
            :visible.sync="importDialog"
            class="dialog-md"
            width="500px"
            :before-close="handleClose1"
          >
            <el-form
              ref="fileForm"
              label-position="center"
              style="width: 100%"
              enctype="multipart/form-data"
            >
              <el-form-item align="center" label="">
                <el-upload
                  ref="upload"
                  class="uploadDialog"
                  name="myfile"
                  action="string"
                  :http-request="httpRequest"
                  :on-change="handleChange"
                  :on-remove="handleRemove"
                  :before-remove="handleBeforeRemove"
                  :limit="1"
                  :file-list="fileList"
                  accept=".xlsx,.xls"
                  :auto-upload="true"
                >
                  <el-button slot="trigger" size="small" type="primary"
                    >上传文件</el-button
                  >
                  <div class="el-upload__tip">1.仅支持上传.xls、.xlsx文件</div>
                  <div class="el-upload__tip">2.文件数据不能超过1000条</div>
                </el-upload>
              </el-form-item>
            </el-form>
            <span slot="footer" class="dialog-footer">
              <el-button size="small" @click="cancelUpload()">取消</el-button>
              <el-button
                type="primary"
                size="small"
                @click="upload()"
                :disabled="uploading"
                >确定导入</el-button
              >
            </span>
          </el-dialog>
        </div>
      </div>

      <el-tabs v-model="activeName" type="card">
        <!-- <el-tabs v-model="activeName" type="card" @tab-click="handleMenuClick"> -->
        <el-tab-pane label="作业区机关" name="first">
          <!--作业区机关界面-->
          <el-table
            :data="tableData"
            border
            style="width: 100%"
            :header-cell-style="{ background: '#F5F7FA', color: '#909399' }"
            stripe
          >
            <el-table-column type="index" align="center" label="序号">
            </el-table-column>
            <el-table-column align="center" prop="name" label="名称">
            </el-table-column>
            <el-table-column align="center" prop="ggxh" label="规格型号">
            </el-table-column>
            <el-table-column align="center" prop="num" label="数量">
            </el-table-column>
            <el-table-column align="center" prop="pbdd" label="配备地点">
            </el-table-column>
            <el-table-column align="center" prop="pbrq" label="配备日期">
            </el-table-column>
            <el-table-column align="center" prop="hyrq" label="换药日期">
            </el-table-column>
            <el-table-column align="center" prop="serialnum" label="编号">
            </el-table-column>
            <el-table-column align="center" prop="principal" label="负责人">
            </el-table-column>

            <el-table-column
              align="center"
              fixed="right"
              prop="approveStatus"
              label="审核状态"
            >
              <template slot-scope="scope">
                <el-tooltip
                  :content="scope.row.approveBz"
                  placement="bottom"
                  effect="light"
                  :disabled="!scope.row.approveBz"
                >
                  <el-badge
                    :is-dot="scope.row.approveBz || scope.row.approveBz === ' '"
                    class="item"
                  >
                    <el-tag
                      :class="scope.row.approveBz ? 'tagstyle' : ''"
                      :type="
                        scope.row.approveStatus == '2'
                          ? 'success'
                          : scope.row.approveStatus == '1'
                          ? 'warning'
                          : scope.row.approveStatus == '0'
                          ? 'info'
                          : 'danger'
                      "
                      disable-transitions
                      >{{
                        scope.row.approveStatus == "2"
                          ? "已通过"
                          : scope.row.approveStatus == "1"
                          ? "未审核"
                          : scope.row.approveStatus == "0"
                          ? "未提交"
                          : "未通过"
                      }}</el-tag
                    >
                  </el-badge>
                </el-tooltip>
              </template>
            </el-table-column>

            <el-table-column
              align="center"
              fixed="right"
              label="操作"
              width="100"
              v-if="
                hasPermission('sys:sjtb:aqgl:xfqctz:edit') ||
                hasPermission('sys:sjtb:aqgl:xfqctz:check')
              "
            >
              <template slot-scope="scope">
                <el-button
                  @click="handleClick(scope.row, 'check')"
                  type="text"
                  v-if="hasPermission('sys:sjtb:aqgl:xfqctz:check')"
                  >查看</el-button
                >
                <el-button
                  @click="handleClick(scope.row, 'edit')"
                  type="text"
                  v-if="hasPermission('sys:sjtb:aqgl:xfqctz:edit')"
                  >编辑</el-button
                >
              </template>
            </el-table-column>
          </el-table>
        </el-tab-pane>

        <el-tab-pane label="东14队" name="second">
          <!--东14队界面-->
          <el-table
            :data="tableData"
            border
            style="width: 100%"
            :header-cell-style="{ background: '#F5F7FA', color: '#909399' }"
            stripe
          >
            <el-table-column type="index" align="center" label="序号">
            </el-table-column>
            <el-table-column align="center" prop="name" label="名称">
            </el-table-column>
            <el-table-column align="center" prop="ggxh" label="规格型号">
            </el-table-column>
            <el-table-column align="center" prop="num" label="数量">
            </el-table-column>
            <el-table-column align="center" prop="pbdd" label="配备地点">
            </el-table-column>
            <el-table-column align="center" prop="pbrq" label="配备日期">
            </el-table-column>
            <el-table-column align="center" prop="hyrq" label="换药日期">
            </el-table-column>
            <el-table-column align="center" prop="serialnum" label="编号">
            </el-table-column>
            <el-table-column align="center" prop="principal" label="负责人">
            </el-table-column>

            <el-table-column
              align="center"
              fixed="right"
              prop="approveStatus"
              label="审核状态"
            >
              <template slot-scope="scope">
                <el-tooltip
                  :content="scope.row.approveBz"
                  placement="bottom"
                  effect="light"
                  :disabled="!scope.row.approveBz"
                >
                  <el-badge
                    :is-dot="scope.row.approveBz || scope.row.approveBz === ' '"
                    class="item"
                  >
                    <el-tag
                      :class="scope.row.approveBz ? 'tagstyle' : ''"
                      :type="
                        scope.row.approveStatus == '2'
                          ? 'success'
                          : scope.row.approveStatus == '1'
                          ? 'warning'
                          : scope.row.approveStatus == '0'
                          ? 'info'
                          : 'danger'
                      "
                      disable-transitions
                      >{{
                        scope.row.approveStatus == "2"
                          ? "已通过"
                          : scope.row.approveStatus == "1"
                          ? "未审核"
                          : scope.row.approveStatus == "0"
                          ? "未提交"
                          : "未通过"
                      }}</el-tag
                    >
                  </el-badge>
                </el-tooltip>
              </template>
            </el-table-column>

            <el-table-column
              align="center"
              fixed="right"
              label="操作"
              width="100"
              v-if="
                hasPermission('sys:sjtb:aqgl:xfqctz:edit') ||
                hasPermission('sys:sjtb:aqgl:xfqctz:check')
              "
            >
              <template slot-scope="scope">
                <el-button
                  @click="handleClick(scope.row, 'check')"
                  type="text"
                  v-if="hasPermission('sys:sjtb:aqgl:xfqctz:check')"
                  >查看</el-button
                >
                <el-button
                  @click="handleClick(scope.row, 'edit')"
                  type="text"
                  v-if="hasPermission('sys:sjtb:aqgl:xfqctz:edit')"
                  >编辑</el-button
                >
              </template>
            </el-table-column>
          </el-table>
        </el-tab-pane>

        <el-tab-pane label="东16污水队" name="third">
          <!-- 东16污水队界面 -->
          <el-table
            :data="tableData"
            border
            style="width: 100%"
            :header-cell-style="{ background: '#F5F7FA', color: '#909399' }"
            stripe
          >
            <el-table-column type="index" align="center" label="序号">
            </el-table-column>
            <el-table-column align="center" prop="name" label="名称">
            </el-table-column>
            <el-table-column align="center" prop="ggxh" label="规格型号">
            </el-table-column>
            <el-table-column align="center" prop="num" label="数量">
            </el-table-column>
            <el-table-column align="center" prop="pbdd" label="配备地点">
            </el-table-column>
            <el-table-column align="center" prop="pbrq" label="配备日期">
            </el-table-column>
            <el-table-column align="center" prop="hyrq" label="换药日期">
            </el-table-column>
            <el-table-column align="center" prop="serial" label="编号">
            </el-table-column>
            <el-table-column align="center" prop="principal" label="负责人">
            </el-table-column>

            <el-table-column
              align="center"
              fixed="right"
              prop="approveStatus"
              label="审核状态"
            >
              <template slot-scope="scope">
                <el-tooltip
                  :content="scope.row.approveBz"
                  placement="bottom"
                  effect="light"
                  :disabled="!scope.row.approveBz"
                >
                  <el-badge
                    :is-dot="scope.row.approveBz || scope.row.approveBz === ' '"
                    class="item"
                  >
                    <el-tag
                      :class="scope.row.approveBz ? 'tagstyle' : ''"
                      :type="
                        scope.row.approveStatus == '2'
                          ? 'success'
                          : scope.row.approveStatus == '1'
                          ? 'warning'
                          : scope.row.approveStatus == '0'
                          ? 'info'
                          : 'danger'
                      "
                      disable-transitions
                      >{{
                        scope.row.approveStatus == "2"
                          ? "已通过"
                          : scope.row.approveStatus == "1"
                          ? "未审核"
                          : scope.row.approveStatus == "0"
                          ? "未提交"
                          : "未通过"
                      }}</el-tag
                    >
                  </el-badge>
                </el-tooltip>
              </template>
            </el-table-column>

            <el-table-column
              align="center"
              fixed="right"
              label="操作"
              width="100"
              v-if="
                hasPermission('sys:sjtb:aqgl:xfqctz:edit') ||
                hasPermission('sys:sjtb:aqgl:xfqctz:check')
              "
            >
              <template slot-scope="scope">
                <el-button
                  @click="handleClick(scope.row, 'check')"
                  type="text"
                  v-if="hasPermission('sys:sjtb:aqgl:xfqctz:check')"
                  >查看</el-button
                >
                <el-button
                  @click="handleClick(scope.row, 'edit')"
                  type="text"
                  v-if="hasPermission('sys:sjtb:aqgl:xfqctz:edit')"
                  >编辑</el-button
                >
              </template>
            </el-table-column>
          </el-table>
        </el-tab-pane>

        <el-tab-pane label="东18队" name="fourth">
          <!--东18队界面-->
          <el-table
            :data="tableData"
            border
            style="width: 100%"
            :header-cell-style="{ background: '#F5F7FA', color: '#909399' }"
            stripe
          >
            <el-table-column type="index" align="center" label="序号">
            </el-table-column>
            <el-table-column align="center" prop="name" label="名称">
            </el-table-column>
            <el-table-column align="center" prop="ggxh" label="规格型号">
            </el-table-column>
            <el-table-column align="center" prop="num" label="数量">
            </el-table-column>
            <el-table-column align="center" prop="pbdd" label="配备地点">
            </el-table-column>
            <el-table-column align="center" prop="pbrq" label="配备日期">
            </el-table-column>
            <el-table-column align="center" prop="hyrq" label="换药日期">
            </el-table-column>
            <el-table-column align="center" prop="serialnum" label="编号">
            </el-table-column>
            <el-table-column align="center" prop="principal" label="负责人">
            </el-table-column>

            <el-table-column
              align="center"
              fixed="right"
              prop="approveStatus"
              label="审核状态"
            >
              <template slot-scope="scope">
                <el-tooltip
                  :content="scope.row.approveBz"
                  placement="bottom"
                  effect="light"
                  :disabled="!scope.row.approveBz"
                >
                  <el-badge
                    :is-dot="scope.row.approveBz || scope.row.approveBz === ' '"
                    class="item"
                  >
                    <el-tag
                      :class="scope.row.approveBz ? 'tagstyle' : ''"
                      :type="
                        scope.row.approveStatus == '2'
                          ? 'success'
                          : scope.row.approveStatus == '1'
                          ? 'warning'
                          : scope.row.approveStatus == '0'
                          ? 'info'
                          : 'danger'
                      "
                      disable-transitions
                      >{{
                        scope.row.approveStatus == "2"
                          ? "已通过"
                          : scope.row.approveStatus == "1"
                          ? "未审核"
                          : scope.row.approveStatus == "0"
                          ? "未提交"
                          : "未通过"
                      }}</el-tag
                    >
                  </el-badge>
                </el-tooltip>
              </template>
            </el-table-column>

            <el-table-column
              align="center"
              fixed="right"
              label="操作"
              width="100"
              v-if="
                hasPermission('sys:sjtb:aqgl:xfqctz:edit') ||
                hasPermission('sys:sjtb:aqgl:xfqctz:check')
              "
            >
              <template slot-scope="scope">
                <el-button
                  @click="handleClick(scope.row, 'check')"
                  type="text"
                  v-if="hasPermission('sys:sjtb:aqgl:xfqctz:check')"
                  >查看</el-button
                >
                <el-button
                  @click="handleClick(scope.row, 'edit')"
                  type="text"
                  v-if="hasPermission('sys:sjtb:aqgl:xfqctz:edit')"
                  >编辑</el-button
                >
              </template>
            </el-table-column>
          </el-table>
        </el-tab-pane>

        <el-tab-pane label="升382队" name="fifth">
          <!--升382队界面-->
          <el-table
            :data="tableData"
            border
            style="width: 100%"
            :header-cell-style="{ background: '#F5F7FA', color: '#909399' }"
            stripe
          >
            <el-table-column type="index" align="center" label="序号">
            </el-table-column>
            <el-table-column align="center" prop="name" label="名称">
            </el-table-column>
            <el-table-column align="center" prop="ggxh" label="规格型号">
            </el-table-column>
            <el-table-column align="center" prop="num" label="数量">
            </el-table-column>
            <el-table-column align="center" prop="pbdd" label="配备地点">
            </el-table-column>
            <el-table-column align="center" prop="pbrq" label="配备日期">
            </el-table-column>
            <el-table-column align="center" prop="hyrq" label="换药日期">
            </el-table-column>
            <el-table-column align="center" prop="serialnum" label="编号">
            </el-table-column>
            <el-table-column align="center" prop="principal" label="负责人">
            </el-table-column>

            <el-table-column
              align="center"
              fixed="right"
              prop="approveStatus"
              label="审核状态"
            >
              <template slot-scope="scope">
                <el-tooltip
                  :content="scope.row.approveBz"
                  placement="bottom"
                  effect="light"
                  :disabled="!scope.row.approveBz"
                >
                  <el-badge
                    :is-dot="scope.row.approveBz || scope.row.approveBz === ' '"
                    class="item"
                  >
                    <el-tag
                      :class="scope.row.approveBz ? 'tagstyle' : ''"
                      :type="
                        scope.row.approveStatus == '2'
                          ? 'success'
                          : scope.row.approveStatus == '1'
                          ? 'warning'
                          : scope.row.approveStatus == '0'
                          ? 'info'
                          : 'danger'
                      "
                      disable-transitions
                      >{{
                        scope.row.approveStatus == "2"
                          ? "已通过"
                          : scope.row.approveStatus == "1"
                          ? "未审核"
                          : scope.row.approveStatus == "0"
                          ? "未提交"
                          : "未通过"
                      }}</el-tag
                    >
                  </el-badge>
                </el-tooltip>
              </template>
            </el-table-column>

            <el-table-column
              align="center"
              fixed="right"
              label="操作"
              width="100"
              v-if="
                hasPermission('sys:sjtb:aqgl:xfqctz:edit') ||
                hasPermission('sys:sjtb:aqgl:xfqctz:check')
              "
            >
              <template slot-scope="scope">
                <el-button
                  @click="handleClick(scope.row, 'check')"
                  type="text"
                  v-if="hasPermission('sys:sjtb:aqgl:xfqctz:check')"
                  >查看</el-button
                >
                <el-button
                  @click="handleClick(scope.row, 'edit')"
                  type="text"
                  v-if="hasPermission('sys:sjtb:aqgl:xfqctz:edit')"
                  >编辑</el-button
                >
              </template>
            </el-table-column>
          </el-table>
        </el-tab-pane>

        <el-tab-pane label="东162队" name="sixth">
          <!--东162队界面-->
          <el-table
            :data="tableData"
            border
            style="width: 100%"
            :header-cell-style="{ background: '#F5F7FA', color: '#909399' }"
            stripe
          >
            <el-table-column type="index" align="center" label="序号">
            </el-table-column>
            <el-table-column align="center" prop="name" label="名称">
            </el-table-column>
            <el-table-column align="center" prop="ggxh" label="规格型号">
            </el-table-column>
            <el-table-column align="center" prop="num" label="数量">
            </el-table-column>
            <el-table-column align="center" prop="pbdd" label="配备地点">
            </el-table-column>
            <el-table-column align="center" prop="pbrq" label="配备日期">
            </el-table-column>
            <el-table-column align="center" prop="hyrq" label="换药日期">
            </el-table-column>
            <el-table-column align="center" prop="serialnum" label="编号">
            </el-table-column>
            <el-table-column align="center" prop="principal" label="负责人">
            </el-table-column>

            <el-table-column
              align="center"
              fixed="right"
              prop="approveStatus"
              label="审核状态"
            >
              <template slot-scope="scope">
                <el-tooltip
                  :content="scope.row.approveBz"
                  placement="bottom"
                  effect="light"
                  :disabled="!scope.row.approveBz"
                >
                  <el-badge
                    :is-dot="scope.row.approveBz || scope.row.approveBz === ' '"
                    class="item"
                  >
                    <el-tag
                      :class="scope.row.approveBz ? 'tagstyle' : ''"
                      :type="
                        scope.row.approveStatus == '2'
                          ? 'success'
                          : scope.row.approveStatus == '1'
                          ? 'warning'
                          : scope.row.approveStatus == '0'
                          ? 'info'
                          : 'danger'
                      "
                      disable-transitions
                      >{{
                        scope.row.approveStatus == "2"
                          ? "已通过"
                          : scope.row.approveStatus == "1"
                          ? "未审核"
                          : scope.row.approveStatus == "0"
                          ? "未提交"
                          : "未通过"
                      }}</el-tag
                    >
                  </el-badge>
                </el-tooltip>
              </template>
            </el-table-column>

            <el-table-column
              align="center"
              fixed="right"
              label="操作"
              width="100"
              v-if="
                hasPermission('sys:sjtb:aqgl:xfqctz:edit') ||
                hasPermission('sys:sjtb:aqgl:xfqctz:check')
              "
            >
              <template slot-scope="scope">
                <el-button
                  @click="handleClick(scope.row, 'check')"
                  type="text"
                  v-if="hasPermission('sys:sjtb:aqgl:xfqctz:check')"
                  >查看</el-button
                >
                <el-button
                  @click="handleClick(scope.row, 'edit')"
                  type="text"
                  v-if="hasPermission('sys:sjtb:aqgl:xfqctz:edit')"
                  >编辑</el-button
                >
              </template>
            </el-table-column>
          </el-table>
        </el-tab-pane>

        <el-tab-pane label="升371队" name="seventh">
          <!--升371队界面-->
          <el-table
            :data="tableData"
            border
            style="width: 100%"
            :header-cell-style="{ background: '#F5F7FA', color: '#909399' }"
            stripe
          >
            <el-table-column type="index" align="center" label="序号">
            </el-table-column>
            <el-table-column align="center" prop="name" label="名称">
            </el-table-column>
            <el-table-column align="center" prop="ggxh" label="规格型号">
            </el-table-column>
            <el-table-column align="center" prop="num" label="数量">
            </el-table-column>
            <el-table-column align="center" prop="pbdd" label="配备地点">
            </el-table-column>
            <el-table-column align="center" prop="pbrq" label="配备日期">
            </el-table-column>
            <el-table-column align="center" prop="hyrq" label="换药日期">
            </el-table-column>
            <el-table-column align="center" prop="serialnum" label="编号">
            </el-table-column>
            <el-table-column align="center" prop="principal" label="负责人">
            </el-table-column>

            <el-table-column
              align="center"
              fixed="right"
              prop="approveStatus"
              label="审核状态"
            >
              <template slot-scope="scope">
                <el-tooltip
                  :content="scope.row.approveBz"
                  placement="bottom"
                  effect="light"
                  :disabled="!scope.row.approveBz"
                >
                  <el-badge
                    :is-dot="scope.row.approveBz || scope.row.approveBz === ' '"
                    class="item"
                  >
                    <el-tag
                      :class="scope.row.approveBz ? 'tagstyle' : ''"
                      :type="
                        scope.row.approveStatus == '2'
                          ? 'success'
                          : scope.row.approveStatus == '1'
                          ? 'warning'
                          : scope.row.approveStatus == '0'
                          ? 'info'
                          : 'danger'
                      "
                      disable-transitions
                      >{{
                        scope.row.approveStatus == "2"
                          ? "已通过"
                          : scope.row.approveStatus == "1"
                          ? "未审核"
                          : scope.row.approveStatus == "0"
                          ? "未提交"
                          : "未通过"
                      }}</el-tag
                    >
                  </el-badge>
                </el-tooltip>
              </template>
            </el-table-column>

            <el-table-column
              align="center"
              fixed="right"
              label="操作"
              width="100"
              v-if="
                hasPermission('sys:sjtb:aqgl:xfqctz:edit') ||
                hasPermission('sys:sjtb:aqgl:xfqctz:check')
              "
            >
              <template slot-scope="scope">
                <el-button
                  @click="handleClick(scope.row, 'check')"
                  type="text"
                  v-if="hasPermission('sys:sjtb:aqgl:xfqctz:check')"
                  >查看</el-button
                >
                <el-button
                  @click="handleClick(scope.row, 'edit')"
                  type="text"
                  v-if="hasPermission('sys:sjtb:aqgl:xfqctz:edit')"
                  >编辑</el-button
                >
              </template>
            </el-table-column>
          </el-table>
        </el-tab-pane>

        <el-tab-pane label="应急抢险队" name="eighth">
          <!--应急抢险队界面-->
          <el-table
            :data="tableData"
            border
            style="width: 100%"
            :header-cell-style="{ background: '#F5F7FA', color: '#909399' }"
            stripe
          >
            <el-table-column type="index" label="序号"> </el-table-column>
            <el-table-column align="center" prop="name" label="名称">
            </el-table-column>
            <el-table-column align="center" prop="ggxh" label="规格型号">
            </el-table-column>
            <el-table-column align="center" prop="num" label="数量">
            </el-table-column>
            <el-table-column align="center" prop="pbdd" label="配备地点">
            </el-table-column>
            <el-table-column align="center" prop="pbrq" label="配备日期">
            </el-table-column>
            <el-table-column align="center" prop="hyrq" label="换药日期">
            </el-table-column>
            <el-table-column align="center" prop="serialnum" label="编号">
            </el-table-column>
            <el-table-column align="center" prop="principal" label="负责人">
            </el-table-column>

            <el-table-column
              align="center"
              fixed="right"
              prop="approveStatus"
              label="审核状态"
            >
              <template slot-scope="scope">
                <el-tooltip
                  :content="scope.row.approveBz"
                  placement="bottom"
                  effect="light"
                  :disabled="!scope.row.approveBz"
                >
                  <el-badge
                    :is-dot="scope.row.approveBz || scope.row.approveBz === ' '"
                    class="item"
                  >
                    <el-tag
                      :class="scope.row.approveBz ? 'tagstyle' : ''"
                      :type="
                        scope.row.approveStatus == '2'
                          ? 'success'
                          : scope.row.approveStatus == '1'
                          ? 'warning'
                          : scope.row.approveStatus == '0'
                          ? 'info'
                          : 'danger'
                      "
                      disable-transitions
                      >{{
                        scope.row.approveStatus == "2"
                          ? "已通过"
                          : scope.row.approveStatus == "1"
                          ? "未审核"
                          : scope.row.approveStatus == "0"
                          ? "未提交"
                          : "未通过"
                      }}</el-tag
                    >
                  </el-badge>
                </el-tooltip>
              </template>
            </el-table-column>

            <el-table-column
              align="center"
              fixed="right"
              label="操作"
              width="100"
              v-if="
                hasPermission('sys:sjtb:aqgl:xfqctz:edit') ||
                hasPermission('sys:sjtb:aqgl:xfqctz:check')
              "
            >
              <template slot-scope="scope">
                <el-button
                  @click="handleClick(scope.row, 'check')"
                  type="text"
                  v-if="hasPermission('sys:sjtb:aqgl:xfqctz:check')"
                  >查看</el-button
                >
                <el-button
                  @click="handleClick(scope.row, 'edit')"
                  type="text"
                  v-if="hasPermission('sys:sjtb:aqgl:xfqctz:edit')"
                  >编辑</el-button
                >
              </template>
            </el-table-column>
          </el-table>
        </el-tab-pane>

        <el-tab-pane label="地工队" name="ninth">
          <!--地工队界面-->
          <el-table
            :data="tableData"
            border
            style="width: 100%"
            :header-cell-style="{ background: '#F5F7FA', color: '#909399' }"
            stripe
          >
            <el-table-column type="index" align="center" label="序号">
            </el-table-column>
            <el-table-column align="center" prop="name" label="名称">
            </el-table-column>
            <el-table-column align="center" prop="ggxh" label="规格型号">
            </el-table-column>
            <el-table-column align="center" prop="num" label="数量">
            </el-table-column>
            <el-table-column align="center" prop="pbdd" label="配备地点">
            </el-table-column>
            <el-table-column align="center" prop="pbrq" label="配备日期">
            </el-table-column>
            <el-table-column align="center" prop="hyrq" label="换药日期">
            </el-table-column>
            <el-table-column align="center" prop="serialnum" label="编号">
            </el-table-column>
            <el-table-column align="center" prop="principal" label="负责人">
            </el-table-column>

            <el-table-column
              align="center"
              fixed="right"
              prop="approveStatus"
              label="审核状态"
            >
              <template slot-scope="scope">
                <el-tooltip
                  :content="scope.row.approveBz"
                  placement="bottom"
                  effect="light"
                  :disabled="!scope.row.approveBz"
                >
                  <el-badge
                    :is-dot="scope.row.approveBz || scope.row.approveBz === ' '"
                    class="item"
                  >
                    <el-tag
                      :class="scope.row.approveBz ? 'tagstyle' : ''"
                      :type="
                        scope.row.approveStatus == '2'
                          ? 'success'
                          : scope.row.approveStatus == '1'
                          ? 'warning'
                          : scope.row.approveStatus == '0'
                          ? 'info'
                          : 'danger'
                      "
                      disable-transitions
                      >{{
                        scope.row.approveStatus == "2"
                          ? "已通过"
                          : scope.row.approveStatus == "1"
                          ? "未审核"
                          : scope.row.approveStatus == "0"
                          ? "未提交"
                          : "未通过"
                      }}</el-tag
                    >
                  </el-badge>
                </el-tooltip>
              </template>
            </el-table-column>

            <el-table-column
              align="center"
              fixed="right"
              label="操作"
              width="100"
              v-if="
                hasPermission('sys:sjtb:aqgl:xfqctz:edit') ||
                hasPermission('sys:sjtb:aqgl:xfqctz:check')
              "
            >
              <template slot-scope="scope">
                <el-button
                  @click="handleClick(scope.row, 'check')"
                  type="text"
                  v-if="hasPermission('sys:sjtb:aqgl:xfqctz:check')"
                  >查看</el-button
                >
                <el-button
                  @click="handleClick(scope.row, 'edit')"
                  type="text"
                  v-if="hasPermission('sys:sjtb:aqgl:xfqctz:edit')"
                  >编辑</el-button
                >
              </template>
            </el-table-column>
          </el-table>
        </el-tab-pane>

        <el-tab-pane label="食堂" name="tenth">
          <!--食堂界面-->
          <el-table
            :data="tableData"
            border
            style="width: 100%"
            :header-cell-style="{ background: '#F5F7FA', color: '#909399' }"
            stripe
          >
            <el-table-column type="index" align="center" label="序号">
            </el-table-column>
            <el-table-column align="center" prop="name" label="名称">
            </el-table-column>
            <el-table-column align="center" prop="ggxh" label="规格型号">
            </el-table-column>
            <el-table-column align="center" prop="num" label="数量">
            </el-table-column>
            <el-table-column align="center" prop="pbdd" label="配备地点">
            </el-table-column>
            <el-table-column align="center" prop="pbrq" label="配备日期">
            </el-table-column>
            <el-table-column align="center" prop="hyrq" label="换药日期">
            </el-table-column>
            <el-table-column align="center" prop="serialnum" label="编号">
            </el-table-column>
            <el-table-column align="center" prop="principal" label="负责人">
            </el-table-column>

            <el-table-column
              align="center"
              fixed="right"
              prop="approveStatus"
              label="审核状态"
            >
              <template slot-scope="scope">
                <el-tooltip
                  :content="scope.row.approveBz"
                  placement="bottom"
                  effect="light"
                  :disabled="!scope.row.approveBz"
                >
                  <el-badge
                    :is-dot="scope.row.approveBz || scope.row.approveBz === ' '"
                    class="item"
                  >
                    <el-tag
                      :class="scope.row.approveBz ? 'tagstyle' : ''"
                      :type="
                        scope.row.approveStatus == '2'
                          ? 'success'
                          : scope.row.approveStatus == '1'
                          ? 'warning'
                          : scope.row.approveStatus == '0'
                          ? 'info'
                          : 'danger'
                      "
                      disable-transitions
                      >{{
                        scope.row.approveStatus == "2"
                          ? "已通过"
                          : scope.row.approveStatus == "1"
                          ? "未审核"
                          : scope.row.approveStatus == "0"
                          ? "未提交"
                          : "未通过"
                      }}</el-tag
                    >
                  </el-badge>
                </el-tooltip>
              </template>
            </el-table-column>

            <el-table-column
              align="center"
              fixed="right"
              label="操作"
              width="100"
              v-if="
                hasPermission('sys:sjtb:aqgl:xfqctz:edit') ||
                hasPermission('sys:sjtb:aqgl:xfqctz:check')
              "
            >
              <template slot-scope="scope">
                <el-button
                  @click="handleClick(scope.row, 'check')"
                  type="text"
                  v-if="hasPermission('sys:sjtb:aqgl:xfqctz:check')"
                  >查看</el-button
                >
                <el-button
                  @click="handleClick(scope.row, 'edit')"
                  type="text"
                  v-if="hasPermission('sys:sjtb:aqgl:xfqctz:edit')"
                  >编辑</el-button
                >
              </template>
            </el-table-column>
          </el-table>
        </el-tab-pane>
      </el-tabs>

      <!-- 分页器 -->
      <el-pagination
        align="right"
        @size-change="handleSizeChange"
        @current-change="handleCurrentChange"
        :current-page="pageNo"
        :page-sizes="[1, 5, 10, 20, 30]"
        :page-size="pageSize"
        layout="total, sizes, prev, pager, next, jumper"
        :total="total"
      >
      </el-pagination>
    </div>

    <!-- 作业区机关弹出框 -->
    <el-dialog :title="myDialogTitle" :visible.sync="zyqjgFormVisible">
      <el-form
        :inline="true"
        :model="zyqjgForm"
        class="demo-form-inline"
        :disabled="isInput"
        ref="zyqjgForm"
      >
        <el-divider content-position="left">基础信息</el-divider>
        <el-row>
          <el-col :span="12">
            <el-form-item label="单位">
              <el-select
                v-model="zyqjgForm.unit"
                placeholder="请选择单位"
                :disabled="isAble"
              >
                <el-option
                  v-for="item in options"
                  :key="item.value"
                  :label="item.label"
                  :value="item.value"
                >
                </el-option>
              </el-select>
            </el-form-item>
          </el-col>
        </el-row>

        <el-divider content-position="left">详细信息</el-divider>
        <el-row>
          <el-col :span="12">
            <el-form-item label="名称:">
              <el-input
                v-model="zyqjgForm.name"
                placeholder="请输入名称"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="规格型号:">
              <el-input
                v-model="zyqjgForm.ggxh"
                placeholder="请输入规格型号"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="数量:">
              <el-input
                v-model="zyqjgForm.num"
                placeholder="请输入数量"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="配备地点:">
              <el-input
                v-model="zyqjgForm.pbdd"
                placeholder="请输入配备地点"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="配备日期:">
              <el-date-picker
                v-model="zyqjgForm.pbrq"
                type="date"
                placeholder="选择日期时间"
                align="right"
                :picker-options="pickerOptions"
                value-format="yyyy-MM-dd"
              >
              </el-date-picker>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="换药日期:">
              <el-date-picker
                v-model="zyqjgForm.hyrq"
                type="date"
                placeholder="选择日期时间"
                align="right"
                :picker-options="pickerOptions"
                value-format="yyyy-MM-dd"
              >
              </el-date-picker>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="编号">
              <el-input
                v-model="zyqjgForm.serialnum"
                placeholder="请输入编号"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="负责人">
              <el-input
                v-model="zyqjgForm.principal"
                placeholder="请输入负责人"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>
      </el-form>

      <div slot="footer" class="dialog-footer" v-show="!ischeck">
        <el-button @click="close('zyqjgForm')">取 消</el-button>
        <el-button type="primary" @click="submitForm('zyqjgForm')"
          >确 定</el-button
        >
      </div>
    </el-dialog>

    <!-- 东14队弹出框 -->
    <!-- <el-dialog :title="myDialogTitle" :visible.sync="d14dFormVisible">
      <el-form :inline="true" :model="d14dForm" class="demo-form-inline">
        <el-row>
          <el-col :span="12">
            <el-form-item label="名称:">
              <el-input
                v-model="d14dForm.name"
                placeholder="请输入名称"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="规格型号:">
              <el-input
                v-model="d14dForm.ggxh"
                placeholder="请输入规格型号"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="数量:">
              <el-input
                v-model="d14dForm.num"
                placeholder="请输入数量"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="配备地点:">
              <el-input
                v-model="d14dForm.pbdd"
                placeholder="请输入配备地点"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="配备日期:">
              <el-date-picker
                v-model="d14dForm.pbrq"
                type="date"
                placeholder="选择日期时间"
                align="right"
                :picker-options="pickerOptions"
              >
              </el-date-picker>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="换药日期:">
              <el-date-picker
                v-model="d14dForm.hyrq"
                type="date"
                placeholder="选择日期时间"
                align="right"
                :picker-options="pickerOptions"
              >
              </el-date-picker>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="编号">
              <el-input
                v-model="d14dForm.serialnum"
                placeholder="请输入编号"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="负责人">
              <el-input
                v-model="d14dForm.principal"
                placeholder="请输入负责人"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>
      </el-form>

      <div slot="footer" class="dialog-footer" v-show="!ischeck">
        <el-button @click="d14dFormVisible = false">取 消</el-button>
        <el-button type="primary" @click="d14dFormVisible = false"
          >确 定</el-button
        >
      </div>
    </el-dialog> -->

    <!--东16污水队弹出框-->
    <!-- <el-dialog :title="myDialogTitle" :visible.sync="d16wsdFormVisible">
      <el-form :inline="true" :model="d16wsdForm" class="demo-form-inline">
        <el-row>
          <el-col :span="12">
            <el-form-item label="名称:">
              <el-input
                v-model="d16wsdForm.name"
                placeholder="请输入名称"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="规格型号:">
              <el-input
                v-model="d16wsdForm.ggxh"
                placeholder="请输入规格型号"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="数量:">
              <el-input
                v-model="d16wsdForm.num"
                placeholder="请输入数量"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="配备地点:">
              <el-input
                v-model="d16wsdForm.pbdd"
                placeholder="请输入配备地点"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="配备日期:">
              <el-date-picker
                v-model="d16wsdForm.pbrq"
                type="date"
                placeholder="选择日期时间"
                align="right"
                :picker-options="pickerOptions"
              >
              </el-date-picker>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="换药日期:">
              <el-date-picker
                v-model="d16wsdForm.hyrq"
                type="date"
                placeholder="选择日期时间"
                align="right"
                :picker-options="pickerOptions"
              >
              </el-date-picker>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="编号">
              <el-input
                v-model="d16wsdForm.serialnum"
                placeholder="请输入编号"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="负责人">
              <el-input
                v-model="d16wsdForm.principal"
                placeholder="请输入负责人"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>
      </el-form>

      <div slot="footer" class="dialog-footer" v-show="!ischeck">
        <el-button @click="d16wsdFormVisible = false">取 消</el-button>
        <el-button type="primary" @click="d16wsdFormVisible = false"
          >确 定</el-button
        >
      </div>
    </el-dialog> -->

    <!-- 东18队弹出框-->
    <!-- <el-dialog :title="myDialogTitle" :visible.sync="d18dFormVisible">
      <el-form :inline="true" :model="d18dForm" class="demo-form-inline">
        <el-row>
          <el-col :span="12">
            <el-form-item label="名称:">
              <el-input
                v-model="d18dForm.name"
                placeholder="请输入名称"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="规格型号:">
              <el-input
                v-model="d18dForm.ggxh"
                placeholder="请输入规格型号"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="数量:">
              <el-input
                v-model="d18dForm.num"
                placeholder="请输入数量"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="配备地点:">
              <el-input
                v-model="d18dForm.pbdd"
                placeholder="请输入配备地点"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="配备日期:">
              <el-date-picker
                v-model="d18dForm.pbrq"
                type="date"
                placeholder="选择日期时间"
                align="right"
                :picker-options="pickerOptions"
              >
              </el-date-picker>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="换药日期:">
              <el-date-picker
                v-model="d18dForm.hyrq"
                type="date"
                placeholder="选择日期时间"
                align="right"
                :picker-options="pickerOptions"
              >
              </el-date-picker>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="编号">
              <el-input
                v-model="d18dForm.serialnum"
                placeholder="请输入编号"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="负责人">
              <el-input
                v-model="d18dForm.principal"
                placeholder="请输入负责人"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>
      </el-form>

      <div slot="footer" class="dialog-footer" v-show="!ischeck">
        <el-button @click="d18dFormVisible = false">取 消</el-button>
        <el-button type="primary" @click="d18dFormVisible = false"
          >确 定</el-button
        >
      </div>
    </el-dialog> -->

    <!--升382队弹出框-->
    <!-- <el-dialog :title="myDialogTitle" :visible.sync="s382dFormVisible">
      <el-form :inline="true" :model="s382dForm" class="demo-form-inline">
        <el-row>
          <el-col :span="12">
            <el-form-item label="名称:">
              <el-input
                v-model="s382dForm.name"
                placeholder="请输入名称"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="规格型号:">
              <el-input
                v-model="s382dForm.ggxh"
                placeholder="请输入规格型号"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="数量:">
              <el-input
                v-model="s382dForm.num"
                placeholder="请输入数量"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="配备地点:">
              <el-input
                v-model="s382dForm.pbdd"
                placeholder="请输入配备地点"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="配备日期:">
              <el-date-picker
                v-model="s382dForm.pbrq"
                type="date"
                placeholder="选择日期时间"
                align="right"
                :picker-options="pickerOptions"
              >
              </el-date-picker>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="换药日期:">
              <el-date-picker
                v-model="s382dForm.hyrq"
                type="date"
                placeholder="选择日期时间"
                align="right"
                :picker-options="pickerOptions"
              >
              </el-date-picker>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="编号">
              <el-input
                v-model="s382dForm.serialnum"
                placeholder="请输入编号"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="负责人">
              <el-input
                v-model="s382dForm.principal"
                placeholder="请输入负责人"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>
      </el-form>

      <div slot="footer" class="dialog-footer" v-show="!ischeck">
        <el-button @click="s382dFormVisible = false">取 消</el-button>
        <el-button type="primary" @click="s382dFormVisible = false"
          >确 定</el-button
        >
      </div>
    </el-dialog> -->

    <!--东162队弹出框-->
    <!-- <el-dialog :title="myDialogTitle" :visible.sync="d162dFormVisible">
      <el-form :inline="true" :model="d162dForm" class="demo-form-inline">
        <el-divider content-position="left">基础信息</el-divider>
        <el-row>
          <el-col :span="12">
            <el-form-item label="单位:">
              <el-input
                v-model="d162dForm.unit"
                placeholder="请输入单位"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>

        <el-divider content-position="left">详细信息</el-divider>
        <el-row>
          <el-col :span="12">
            <el-form-item label="名称:">
              <el-input
                v-model="d162dForm.name"
                placeholder="请输入名称"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="规格型号:">
              <el-input
                v-model="d162dForm.ggxh"
                placeholder="请输入规格型号"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="数量:">
              <el-input
                v-model="d162dForm.num"
                placeholder="请输入数量"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="配备地点:">
              <el-input
                v-model="d162dForm.pbdd"
                placeholder="请输入配备地点"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="配备日期:">
              <el-date-picker
                v-model="d162dForm.pbrq"
                type="date"
                placeholder="选择日期时间"
                align="right"
                :picker-options="pickerOptions"
              >
              </el-date-picker>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="换药日期:">
              <el-date-picker
                v-model="d162dForm.hyrq"
                type="date"
                placeholder="选择日期时间"
                align="right"
                :picker-options="pickerOptions"
              >
              </el-date-picker>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="编号">
              <el-input
                v-model="d162dForm.serialnum"
                placeholder="请输入编号"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="负责人">
              <el-input
                v-model="d162dForm.principal"
                placeholder="请输入负责人"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>
      </el-form>

      <div slot="footer" class="dialog-footer" v-show="!ischeck">
        <el-button @click="d162dFormVisible = false">取 消</el-button>
        <el-button type="primary" @click="d162dFormVisible = false"
          >确 定</el-button
        >
      </div>
    </el-dialog> -->

    <!--升371队弹出框-->
    <!-- <el-dialog :title="myDialogTitle" :visible.sync="s371dFormVisible">
      <el-form :inline="true" :model="s371dForm" class="demo-form-inline">
        <el-row>
          <el-col :span="12">
            <el-form-item label="名称:">
              <el-input
                v-model="s371dForm.name"
                placeholder="请输入名称"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="规格型号:">
              <el-input
                v-model="s371dForm.ggxh"
                placeholder="请输入规格型号"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="数量:">
              <el-input
                v-model="s371dForm.num"
                placeholder="请输入数量"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="配备地点:">
              <el-input
                v-model="s371dForm.pbdd"
                placeholder="请输入配备地点"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="配备日期:">
              <el-date-picker
                v-model="s371dForm.pbrq"
                type="date"
                placeholder="选择日期时间"
                align="right"
                :picker-options="pickerOptions"
              >
              </el-date-picker>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="换药日期:">
              <el-date-picker
                v-model="s371dForm.hyrq"
                type="date"
                placeholder="选择日期时间"
                align="right"
                :picker-options="pickerOptions"
              >
              </el-date-picker>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="编号">
              <el-input
                v-model="s371dForm.serialnum"
                placeholder="请输入编号"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="负责人">
              <el-input
                v-model="s371dForm.principal"
                placeholder="请输入负责人"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>
      </el-form>

      <div slot="footer" class="dialog-footer" v-show="!ischeck">
        <el-button @click="s371dFormVisible = false">取 消</el-button>
        <el-button type="primary" @click="s371dFormVisible = false"
          >确 定</el-button
        >
      </div>
    </el-dialog> -->

    <!--应急抢险队弹出框-->
    <!-- <el-dialog :title="myDialogTitle" :visible.sync="yjqxdFormVisible">
      <el-form :inline="true" :model="yjqxdForm" class="demo-form-inline">
        <el-row>
          <el-col :span="12">
            <el-form-item label="名称:">
              <el-input
                v-model="yjqxdForm.name"
                placeholder="请输入名称"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="规格型号:">
              <el-input
                v-model="yjqxdForm.ggxh"
                placeholder="请输入规格型号"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="数量:">
              <el-input
                v-model="yjqxdForm.num"
                placeholder="请输入数量"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="配备地点:">
              <el-input
                v-model="yjqxdForm.pbdd"
                placeholder="请输入配备地点"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="配备日期:">
              <el-date-picker
                v-model="yjqxdForm.pbrq"
                type="date"
                placeholder="选择日期时间"
                align="right"
                :picker-options="pickerOptions"
              >
              </el-date-picker>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="换药日期:">
              <el-date-picker
                v-model="yjqxdForm.hyrq"
                type="date"
                placeholder="选择日期时间"
                align="right"
                :picker-options="pickerOptions"
              >
              </el-date-picker>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="编号">
              <el-input
                v-model="yjqxdForm.serialnum"
                placeholder="请输入编号"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="负责人">
              <el-input
                v-model="yjqxdForm.principal"
                placeholder="请输入负责人"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>
      </el-form>

      <div slot="footer" class="dialog-footer" v-show="!ischeck">
        <el-button @click="yjqxdFormVisible = false">取 消</el-button>
        <el-button type="primary" @click="yjqxdFormVisible = false"
          >确 定</el-button
        >
      </div>
    </el-dialog> -->

    <!--地工队弹出框-->
    <!-- <el-dialog :title="myDialogTitle" :visible.sync="dgdFormVisible">
      <el-form :inline="true" :model="dgdForm" class="demo-form-inline">
        <el-row>
          <el-col :span="12">
            <el-form-item label="名称:">
              <el-input
                v-model="dgdForm.name"
                placeholder="请输入名称"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="规格型号:">
              <el-input
                v-model="dgdForm.ggxh"
                placeholder="请输入规格型号"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="数量:">
              <el-input
                v-model="dgdForm.num"
                placeholder="请输入数量"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="配备地点:">
              <el-input
                v-model="dgdForm.pbdd"
                placeholder="请输入配备地点"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="配备日期:">
              <el-date-picker
                v-model="dgdForm.pbrq"
                type="date"
                placeholder="选择日期时间"
                align="right"
                :picker-options="pickerOptions"
              >
              </el-date-picker>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="换药日期:">
              <el-date-picker
                v-model="dgdForm.hyrq"
                type="date"
                placeholder="选择日期时间"
                align="right"
                :picker-options="pickerOptions"
              >
              </el-date-picker>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="编号">
              <el-input
                v-model="dgdForm.serialnum"
                placeholder="请输入编号"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="负责人">
              <el-input
                v-model="dgdForm.principal"
                placeholder="请输入负责人"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>
      </el-form>

      <div slot="footer" class="dialog-footer" v-show="!ischeck">
        <el-button @click="dgdFormVisible = false">取 消</el-button>
        <el-button type="primary" @click="dgdFormVisible = false"
          >确 定</el-button
        >
      </div>
    </el-dialog> -->

    <!--食堂弹出框-->
    <!-- <el-dialog :title="myDialogTitle" :visible.sync="stFormVisible">
      <el-form :inline="true" :model="stForm" class="demo-form-inline">
        <el-row>
          <el-col :span="12">
            <el-form-item label="名称:">
              <el-input
                v-model="stForm.st_name"
                placeholder="请输入名称"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="规格型号:">
              <el-input
                v-model="stForm.st_ggxh"
                placeholder="请输入规格型号"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="数量:">
              <el-input
                v-model="stForm.st_num"
                placeholder="请输入数量"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="配备地点:">
              <el-input
                v-model="stForm.st_pbdd"
                placeholder="请输入配备地点"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="配备日期:">
              <el-date-picker
                v-model="stForm.st_pbrq"
                type="date"
                placeholder="选择日期时间"
                align="right"
                :picker-options="pickerOptions"
              >
              </el-date-picker>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="换药日期:">
              <el-date-picker
                v-model="stForm.st_hyrq"
                type="date"
                placeholder="选择日期时间"
                align="right"
                :picker-options="pickerOptions"
              >
              </el-date-picker>
            </el-form-item>
          </el-col>
        </el-row>

        <el-row>
          <el-col :span="12">
            <el-form-item label="编号">
              <el-input
                v-model="stForm.st_serialnum"
                placeholder="请输入编号"
              ></el-input>
            </el-form-item>
          </el-col>
          <el-col :span="12">
            <el-form-item label="负责人">
              <el-input
                v-model="stForm.st_principal"
                placeholder="请输入负责人"
              ></el-input>
            </el-form-item>
          </el-col>
        </el-row>
      </el-form>

      <div slot="footer" class="dialog-footer" v-show="!ischeck">
        <el-button @click="stFormVisible = false">取 消</el-button>
        <el-button type="primary" @click="stFormVisible = false"
          >确 定</el-button
        >
      </div>
    </el-dialog> -->
  </div>
</template>

<script>
import axios from "axios";
import xfqctzApi from "@/api/xfqctz";
import moment from "moment";
import { getToken } from "@/utils/auth";
export default {
  data() {
    return {
      isInput: false,
      options: [
        { value: "作业区机关", label: "作业区机关" },
        { value: "东14队", label: "东14队" },
        { value: "东16污水队", label: "东16污水队" },
        { value: "东18队", label: "东18队" },
        { value: "升382队", label: "升382队" },
        { value: "东162队", label: "东162队" },
        { value: "升371队", label: "升371队" },
        { value: "应急抢险队", label: "应急抢险队" },
        { value: "地工队", label: "地工队" },
        { value: "食堂", label: "食堂" },
      ],

      isAble: false,
      //数据总条数
      total: 0,
      //当前页码
      pageNo: 1,
      // 分页数
      pageSize: 5,

      currentPageName: "作业区机关",

      activeName: "first",

      //作业区机关数据
      tableData: [],

      //作业区机关表单填报的数据
      zyqjgForm: {
        id: "",
        unit: "",
        name: "", //作业区机关—名称
        ggxh: "", //作业区机关—规格型号
        num: "", //作业区机关—数量
        pbdd: "", //作业区机关—配备地点
        pbrq: "", //作业区机关—配备日期
        hyrq: "", //作业区机关—换药日期
        serialnum: "", //作业区机关—编号
        principal: "", //作业区机关—负责人
      },
      //东14队表单填报数据
      d14dForm: {
        // name: "二氧化碳灭火器", //东14队—名称
        // ggxh: "MT/3", //东14队—规格型号
        // num: "1", //东14队—数量
        // pbdd: "水质岗值班室", //东14队—配备地点
        // pbrq: "2011.11", //东14队—配备日期
        // hyrq: "2020.10.18", //东14队—换药日期
        // serialnum: "D14-MHQ-001", //东14队—编号
        // principal: "周才清", //东14队—负责人
      },

      d16wsdForm: {
        // name: "二氧化碳灭火器", //东16污水队—名称
        // ggxh: "MT3", //东16污水队—规格型号
        // num: "2", //东16污水队—数量
        // pbdd: "加热岗", //东16污水队—配备地点
        // pbrq: "2005.3.10", //东16污水队—配备日期
        // hyrq: "2020.10.18", //东16污水队—换药日期
        // serialnum: "D16-MHQ-001-002", //东16污水队—编号
        // principal: "窦金鹏", //东16污水队—负责人
      },

      d18dForm: {
        // name: "手提式干粉灭火器", //东18队—名称
        // ggxh: "MFZ/ABC8", //东18队—规格型号
        // num: "1", //东18队—数量
        // pbdd: "1 #计量间值班室", //东18队—配备地点
        // pbrq: "2010.5.6", //东18队—配备日期
        // hyrq: "2020.10.20", //东18队—换药日期
        // serialnum: "D18-MHQ-001", //东18队—编号
        // principal: "孟宪辉", //东18队—负责人
      },

      s382dForm: {
        // name: "手提式干粉灭火器", //升382队—名称
        // ggxh: "MFZ/ABC8", //升382队—规格型号
        // num: "2", //升382队—数量
        // pbdd: "10号库", //升382队—配备地点
        // pbrq: "2006.2.10", //升382队—配备日期
        // hyrq: "2020.10.20", //升382队—换药日期
        // serialnum: "S382-MHQ-001～002", //升382队—编号
        // principal: "姚超", //升382队—负责人
      },

      d162dForm: {
        // name: "灭火器", //东162队—名称
        // ggxh: "MFZ-ABC2F", //东162队—规格型号
        // num: "3", //东162队—数量
        // pbdd: "队库房", //东162队—配备地点
        // pbrq: "2011.5.5", //东162队—配备日期
        // hyrq: "2020.10.20", //东162队—换药日期
        // serialnum: "D162-MHQ-001～D162-MHQ-003", //东162队—编号
        // principal: "丁永军", //东162队—负责人
      },

      s371dForm: {
        // name: "手提式干粉灭火器", //升371队—名称
        // ggxh: "MFZ/ABC4", //升371队—规格型号
        // num: "1", //升371队—数量
        // pbdd: "4 #计量间阀组间", //升371队—配备地点
        // pbrq: "2005.8.10", //升371队—配备日期
        // hyrq: "2020.10.20", //升371队—换药日期
        // serialnum: "S371-MHQ-001", //升371队—编号
        // principal: "孟祥煜", //升371队—负责人
      },

      yjqxdForm: {
        // name: "手提式干粉灭火器", //应急抢险队—名称
        // ggxh: "MFZ/ABC1F", //应急抢险队—规格型号
        // num: "1", //应急抢险队—数量
        // pbdd: "黑E788LG", //应急抢险队—配备地点
        // pbrq: "2.15.6.4", //应急抢险队—配备日期
        // hyrq: "2020.10.20", //应急抢险队—换药日期
        // serialnum: "YJ-MHQ-001", //应急抢险队—编号
        // principal: "吴中喜", //应急抢险队—负责人
      },

      dgdForm: {
        // name: "", //地工队—名称
        // ggxh: "", //地工队—规格型号
        // num: "", //地工队—数量
        // pbdd: "", //地工队-配备地点
        // pbrq: "", //地工队-配备日期
        // hyrq: "", //地工队—换药日期
        // serialnum: "", //地工队—编号
        // principal: "", //地工队—负责人
      },

      stForm: {
        // name: "", //食堂—名称
        // ggxh: "", //食堂—规格型号
        // num: "", //食堂—数量
        // pbdd: "", //食堂-配备地点
        // pbrq: "", //食堂-配备日期
        // hyrq: "", //食堂—换药日期
        // serialnum: "", //食堂—编号
        // principal: "", //食堂—负责人
      },

      //时间快捷选择
      pickerOptions: {
        // disabledDate(time) {
        //   return time.getTime() > Date.now();
        // },
        shortcuts: [
          {
            text: "今天",
            onClick(picker) {
              picker.$emit("pick", new Date());
            },
          },
          {
            text: "昨天",
            onClick(picker) {
              const date = new Date();
              date.setTime(date.getTime() - 3600 * 1000 * 24);
              picker.$emit("pick", date);
            },
          },
          {
            text: "一周前",
            onClick(picker) {
              const date = new Date();
              date.setTime(date.getTime() - 3600 * 1000 * 24 * 7);
              picker.$emit("pick", date);
            },
          },
        ],
      },

      //作业区机关编辑框是否显示
      zyqjgFormVisible: false,

      // //东14队编辑框是否显示
      // d14dFormVisible: false,

      // //东16污水队编辑框是否显示
      // d16wsdFormVisible: false,

      // //东18队编辑框是否显示
      // d18dFormVisible: false,

      // //升382队编辑框是否显示
      // s382dFormVisible: false,

      // //东162队编辑框是否显示
      // d162dFormVisible: false,

      // //升371队编辑框是否显示
      // s371dFormVisible: false,

      // //应急抢险队编辑框是否显示
      // yjqxdFormVisible: false,

      // //地工队编辑框是否显示
      // dgdFormVisible: false,

      // //食堂编辑框是否显示
      // stFormVisible: false,

      //弹出框是否是查看
      ischeck: false,

      //弹出框标题
      myDialogTitle: "",

      //作业区机关的可见性
      zyqjgVisable: true,

      // //东14队的可见性
      // d14dVisable: false,

      // //东16污水队的可见性
      // d16wsdVisable: false,

      // //东18队可见性
      // d18dVisable: false,

      // //升382队的可见性
      // s382dVisable: false,

      // //东162队的可见性
      // d162dVisable: false,

      // //升371队的可见性
      // s371dVisable: false,

      // //应急抢险队可见性
      // yjqxdVisable: false,

      // //地工队的可见性
      // dgdVisable: false,

      // //食堂可见性
      // stVisable: false,
      file: null,
      //加载动画
      uploadLoading: false,
      //上传的文件列表
      fileList: [],
      //控制弹出框显示与否
      uploadShowDialog: false,
      //上传地址
      uploadURL: "",
      //loading加载中
      downloadLoading: "",
      importDialog: false,
      fileList: [],
      urlFile: "",
      uploading: true,
      unit: "作业区机关", //单位
    };
  },
  created() {
    this.search();
  },
  methods: {
    /**
     * 根据当前页面查询列表
     */
    async search() {
      console.log("activeName", this.activeName);
      console.log("当前页: ", this.pageNo, "每页条", this.pageSize);
      let res = await xfqctzApi.getXfqctzList(
        this.pageNo,
        this.pageSize,
        this.unit
      );
      console.log("res", res);

      if (this.activeName == "first") {
        this.tableData = res.data.records;
      } else if (this.activeName == "second") {
        this.tableData = res.data.records;
      } else if (this.activeName == "third") {
        this.tableData = res.data.records;
      } else if (this.activeName == "fourth") {
        this.tableData = res.data.records;
      } else if (this.activeName == "fifth") {
        this.tableData = res.data.records;
      } else if (this.activeName == "sixth") {
        this.tableData = res.data.records;
      } else if (this.activeName == "seventh") {
        this.tableData = res.data.records;
      } else if (this.activeName == "eighth") {
        this.tableData = res.data.records;
      } else if (this.activeName == "ninth") {
        this.tableData = res.data.records;
      } else if (this.activeName == "tenth") {
        this.tableData = res.data.records;
      }
      console.log(res.data.total);
      this.total = res.data.total;
      this.pageSize = res.data.size;
      console.log(this.total);
    },
    //      async search() {
    //       console.log('activeName',this.activeName)
    //       if(this.activeName=='first'){
    //         this.unit='作业区机关'
    //       }else if(this.activeName=='second'){
    //         this.unit='东14队'
    //       }
    //       let res = await xfqctzApi.getXfqctzList(this.pageNo,this.pageSize,this.unit);
    //       console.log(res)
    //       debugger
    //         var arr=[];
    //         var arr1=[];
    //         var arr2=[];
    //         var arr3=[];
    //         var arr4=[];
    //         var arr5=[];
    //         var arr6=[];
    //         var arr7=[];
    //         var arr8=[];
    //         var arr9=[];
    //         var j=0;
    //         var k=0;
    //         var o=0;
    //         var p=0;
    //         var q=0;
    //         var r=0;
    //         var s=0;
    //         var t=0;
    //         var u=0;
    //         var v=0;
    //         for (var i=0;i<res.data.total;i++) {
    //           if(this.currentPageName==='作业区机关') {
    //             if(res.data.records[i].unit==="作业区机关") {
    //               this.box=res.data.records[i];
    //               console.log(this.box);
    //               arr.push(this.box);
    //               // console.log(arr)
    //               // 总数量
    //               j+=1;
    //             }
    //           }
    //         }
    //         // console.log(j);

    //         // console.log(this.total)
    //         for(var i=0;i<=j;i++)
    //         {
    //           this.tableData=arr;
    //           console.log(arr)
    //           this.total = arr.length;
    //         }

    //         for (var i=0;i<res.data.total;i++) {
    //           // console.log(res.data.total);
    //           if(this.currentPageName==='东14队'){
    //           // this.d14dData==="";
    //             if(res.data.records[i].unit==="东14队")
    //             {
    //               this.box1=res.data.records[i];
    //               console.log(this.box1)
    //               arr1.push(this.box1);
    //               k++;
    //             }
    //           }
    //         }
    //         // console.log(k);
    //         // this.total=k;
    //         console.log(this.total);
    //         for(var i=0;i<=k;i++)
    //         {
    //           this.d14dData=arr1;
    //           this.total = arr1.length;
    //         }

    //         for (var i=0;i<res.data.total;i++) {
    //           // console.log(res.data.total);
    //           if(this.currentPageName==='东16污水队'){
    //           // this.d14dData==="";
    //             if(res.data.records[i].unit==="东16污水队")
    //             {
    //               this.box1=res.data.records[i];
    //               console.log(this.box1)
    //               arr2.push(this.box1);
    //               o++;
    //             }
    //           }
    //         }
    //         console.log(o);
    //         this.total = o;
    //         console.log(this.total)
    //         for(var i=0;i<=o;i++)
    //         {
    //           this.d16wsdData=arr2;
    //         }

    //         for (var i=0;i<res.data.total;i++) {
    //           // console.log(res.data.total);
    //           if(this.currentPageName==='东18队'){
    //           // this.d14dData==="";
    //             if(res.data.records[i].unit==="东18队")
    //             {
    //               this.box1=res.data.records[i];
    //               console.log(this.box1)
    //               arr3.push(this.box1);
    //               p++;
    //             }
    //           }
    //         }
    //         console.log(p);
    //         this.total = p;
    //         console.log(this.total)
    //         for(var i=0;i<=p;i++)
    //         {
    //           this.d18dData=arr3;
    //         }

    //         for (var i=0;i<res.data.total;i++) {
    //           // console.log(res.data.total);
    //           if(this.currentPageName==='升382队'){
    //           // this.d14dData==="";
    //             if(res.data.records[i].unit==="升382队")
    //             {
    //               this.box1=res.data.records[i];
    //               console.log(this.box1)
    //               arr4.push(this.box1);
    //               q++;
    //             }
    //           }
    //         }
    //         console.log(q);
    //         this.total = q;
    //         console.log(this.total)
    //         for(var i=0;i<=q;i++)
    //         {
    //           this.s382dData=arr4;
    //         }

    //         for (var i=0;i<res.data.total;i++) {
    //           if(this.currentPageName==='东162队'){
    //           // this.d14dData==="";
    //             if(res.data.records[i].unit==="东162队")
    //             {
    //               this.box1=res.data.records[i];
    //               // console.log(this.box1)
    //               arr5.push(this.box1);
    //               r++;
    //             }
    //           }
    //         }
    //         console.log(r);
    //         this.total = r;
    //         // console.log(this.total)
    //         for(var i=0;i<=r;i++)
    //         {
    //           this.d162dData=arr5;
    //         }

    //         for (var i=0;i<res.data.total;i++) {
    //           if(this.currentPageName==='升371队') {
    //             if(res.data.records[i].unit==="升371队") {
    //               this.box=res.data.records[i];
    //               // console.log(this.box);
    //               arr6.push(this.box);
    //               // console.log(arr)
    //               // 总数量
    //               s++;
    //             }
    //           }
    //         }
    //         // console.log(j);
    //         this.total = s;
    //         // console.log(this.total)
    //         for(var i=0;i<=s;i++)
    //         {
    //           this.s371dData=arr6;
    //         }

    //         for (var i=0;i<res.data.total;i++) {
    //           if(this.currentPageName==='应急抢险队') {
    //             if(res.data.records[i].unit==="应急抢险队") {
    //               this.box=res.data.records[i];
    //               // console.log(this.box);
    //               arr7.push(this.box);
    //               // console.log(arr)
    //               // 总数量
    //               t++;
    //             }
    //           }
    //         }
    //         // console.log(j);
    //         this.total = t;
    //         // console.log(this.total)
    //         for(var i=0;i<=t;i++)
    //         {
    //           this.yjqxdData=arr7;
    //         }

    //         for (var i=0;i<res.data.total;i++) {
    //           if(this.currentPageName==='地工队') {
    //             if(res.data.records[i].unit==="地工队") {
    //               this.box=res.data.records[i];
    //               // console.log(this.box);
    //               arr8.push(this.box);
    //               // console.log(arr)
    //               // 总数量
    //               u++;
    //             }
    //           }
    //         }
    //         // console.log(j);
    //         this.total = u;
    //         // console.log(this.total)
    //         for(var i=0;i<=u;i++)
    //         {
    //           this.dgdData=arr8;
    //         }

    //         for (var i=0;i<res.data.total;i++) {
    //           if(this.currentPageName==='食堂') {
    //             if(res.data.records[i].unit==="食堂") {
    //               this.box=res.data.records[i];
    //               // console.log(this.box);
    //               arr9.push(this.box);
    //               // console.log(arr)
    //               // 总数量
    //               v++;
    //             }
    //           }
    //         }
    //         console.log(v);
    //         this.total = v;
    //         // console.log(this.total)
    //         for(var i=0;i<=v;i++)
    //         {
    //           this.stData=arr9;
    //         }
    //         // for (var i=0;i<res.data.total;i++) {
    //         //   console.log(res.data.total);
    //         //   if(this.currentPageName==='东16污水队'){
    //         //   // this.d14dData==="";
    //         //     if(res.data.records[i].unit==="东16污水队")
    //         //     {
    //         //       this.box1=res.data.records[i];
    //         //       console.log(this.box1)
    //         //       arr3.push(this.box1);
    //         //       p++;
    //         //     }
    //         //   }
    //         // }
    //         // console.log(p);
    //         // this.total = p;
    //         // console.log(this.total)
    //         // for(var i=0;i<p;i++)
    //         // {
    //         //   this.d16wsdData=arr3;
    //         // }

    //       //     }
    //       //     else if(this.currentPageName==='东14队'){
    //       //     // this.d14dData==="";
    //       //     if(res.data.records[i].unit==="东14队")
    //       //     {
    //       //       this.box1=res.data.records[i];
    //       //       console.log(this.box1)
    //       //       arr1.push(this.box1);
    //       //       k++;
    //       //       console.log(k);
    //       //       this.total = k;
    //       //       console.log(this.total)
    //       //       for(var i=0;i<k;i++)
    //       //       {
    //       //         this.d14dData=arr1;
    //       //       }
    //       //     }
    //       //   }
    //       // }
    //       //   else if(this.currentPageName==='东16污水队') {
    //       //     // this.d16wsdData==="";
    //       //     if(res.data.records[i].unit==="东16污水队") {
    //       //       this.box=res.data.records[i];
    //       //       console.log(this.box)
    //       //       arr2.push(this.box);
    //       //       o++;
    //       //       console.log(o);
    //       //       this.total = o;
    //       //       console.log(this.total)
    //       //       for(var i=0;i<o;i++)
    //       //       {
    //       //         this.d16wsdData=arr2;
    //       //       }
    //       //     }
    //       //   }
    //       //   else if(this.currentPageName==='东18队') {
    //       //     // this.d18dData==="";
    //       //     if(res.data.records[i].unit==="东18队") {
    //       //       this.box=res.data.records[i];
    //       //       console.log(this.box)
    //       //       arr3.push(this.box);
    //       //       p++;
    //       //       console.log(p);
    //       //       this.total = p;
    //       //       console.log(this.total)
    //       //       for(var i=0;i<p;i++)
    //       //       {
    //       //         this.d18dData=arr3;
    //       //       }
    //       //     }
    //       //   }
    //       //   else if(this.currentPageName==='升382队'){
    //       //     // this.d14dData==="";
    //       //     if(res.data.records[i].unit==="升382队")
    //       //     {
    //       //       this.box=res.data.records[i];
    //       //       console.log(this.box)
    //       //       arr4.push(this.box);
    //       //       q++;
    //       //       console.log(q);
    //       //       this.total = q;
    //       //       console.log(this.total)
    //       //       for(var i=0;i<q;i++)
    //       //       {
    //       //         this.s382dData=arr4;
    //       //       }
    //       //     }
    //       //   }
    //       // }

    // // if(this.currentPageName==='作业区机关'){
    // //   //发送查询请求
    // //   let res = await xfqctzApi.getXfqctzList(this.pageNo,this.pageSize);
    // //     //判断是否成功
    // //     if(res.success){
    // //         // console.log(res.data);
    // //        //赋值
    // //         this.tableData = res.data.records;
    // //         //总数量
    // //         this.total = res.data.total;
    // //         var arr=[];
    // //         var j=0;
    // //         for (var i=0;i<res.data.total;i++) {
    // //           if(res.data.records[i].unit==="作业区机关") {
    // //           console.log(res.data.records[i].unit);
    // //           this.box=res.data.records[i];
    // //           console.log(this.box);
    // //           arr.push(this.box);
    // //           console.log(arr)
    // //           //总数量
    // //           j++;
    // //           }
    // //         }
    // //         console.log(j);
    // //         this.total = j;
    // //         console.log(this.total)
    // //         for(var i=0;i<j;i++)
    // //         {
    // //           this.tableData=arr;
    // //         }
    // // }

    // //   }
    // // else if(this.currentPageName==='东14队') {
    // //   //发送查询请求
    // //   let res = await xfqctzApi.getXfqctzList(this.pageNo, this.pageSize);
    // //   //判断是否成功
    // //   if (res.success) {

    // //   //赋值
    // //     this.d14dData = res.data.records;
    // //     // //总数量
    // //     this.total = res.data.total;
    // //     console.log(this.total)
    // //       var arr1=[];
    // //         var k=0;
    // //         for (var i=0;i<res.data.total;i++) {
    // //           if(res.data.records[i].unit==="东14队") {
    // //           console.log(res.data.records[i].unit);
    // //           this.box=res.data.records[i];
    // //           console.log(this.box);
    // //           arr1.push(this.box);
    // //           console.log(arr1)
    // //           //总数量
    // //           k++;
    // //         }
    // //         console.log(k);
    // //         this.total = k;
    // //         console.log(this.total)
    // //         for(var i=0;i<k;i++)
    // //         {
    // //           this.d14dData=arr1;
    // //         }
    // //       }
    // //   }
    // // }
    // // if(this.currentPageName==='东16污水队') {
    // //     //发送查询请求
    // //     let res = await xfqctzApi.getXfqctzList(this.pageNo, this.pageSize);
    // //     //判断是否成功
    // //     if (res.success) {
    // //       console.log(res.data);
    // //       // //赋值
    // //       this.d16wsdData = res.data.records;
    // //       // //总数量
    // //       this.total = res.data.total;
    // //     }
    // // }else if(this.currentPageName==='东18队') {
    // //   //发送查询请求
    // //   let res = await xfqctzApi.getXfqctzList(this.pageNo, this.pageSize);
    // //   //判断是否成功
    // //   if (res.success) {
    // //     console.log(res.data);
    // //     // //赋值
    // //     this.d18dData = res.data.records;
    // //     // //总数量
    // //     this.total = res.data.total;
    // //   }
    // // }
    // // if(this.currentPageName==='升382队') {
    // //   //发送查询请求
    // //   let res = await xfqctzApi.getXfqctzList(this.pageNo, this.pageSize);
    // //   //判断是否成功
    // //   if (res.success) {
    // //     console.log(res.data);
    // //     // //赋值
    // //     this.s382dData = res.data.records;
    // //     // //总数量
    // //     this.total = res.data.total;
    // //   }

    // // }else
    // // if(this.currentPageName==='东162队') {
    // //   //发送查询请求
    // //   let res = await xfqctzApi.getXfqctzList(this.pageNo, this.pageSize);
    // //   //判断是否成功
    // //   if (res.success) {
    // //     console.log(res.data);
    // //     // //赋值
    // //     this.d162dData = res.data.records;
    // //     // //总数量
    // //     this.total = res.data.total;
    // //   }
    // // }
    // // else
    // // if(this.currentPageName==='升371队') {
    // //   //发送查询请求
    // //   let res = await xfqctzApi.getXfqctzList(this.pageNo, this.pageSize);
    // //   //判断是否成功
    // //   if (res.success) {
    // //     console.log(res.data);
    // //     // //赋值
    // //     this.s371dData = res.data.records;
    // //     // //总数量
    // //     this.total = res.data.total;
    // //   }
    // // }else if(this.currentPageName==='应急抢险队') {
    // //   //发送查询请求
    // //   let res = await xfqctzApi.getXfqctzList(this.pageNo, this.pageSize);
    // //   //判断是否成功
    // //   if (res.success) {
    // //     console.log(res.data);
    // //     // //赋值
    // //     this.yjqxdData= res.data.records;
    // //     // //总数量
    // //     this.total = res.data.total;
    // //   }
    // // }
    // // else if(this.currentPageName==='地工队') {
    // //   //发送查询请求
    // //   let res = await xfqctzApi.getXfqctzList(this.pageNo, this.pageSize);
    // //   //判断是否成功
    // //   if (res.success) {
    // //     console.log(res.data);
    // //     // //赋值
    // //     this.dgdData= res.data.records;
    // //     // //总数量
    // //     this.total = res.data.total;
    // //   }
    // // }
    // // else if(this.currentPageName==='食堂') {
    // //   //发送查询请求
    // //   let res = await xfqctzApi.getXfqctzList(this.pageNo, this.pageSize);
    // //   //判断是否成功
    // //   if (res.success) {
    // //     console.log(res.data);
    // //     // //赋值
    // //     this.stData= res.data.records;
    // //     // //总数量
    // //     this.total = res.data.total;
    // //   }
    // //  }
    // },
    //关闭对话框
    handleClose(done) {
      // 清空表单
      // this.$refs['syjForm'].resetFields();
      // 清空表单校验，避免再次进来会出现上次校验的记录
      this.$refs["zyqjgForm"].clearValidate();
      done();
    },
    handleClose1(done) {
      this.urlFile = "";
      this.fileList = [];
      done();
    },
    // 弹框关闭触发
    close(formName) {
      this.dialogFormVisible = false;
      // 清空表单
      // this.$refs[formName].resetFields();
      // 清空表单校验，避免再次进来会出现上次校验的记录
      this.$refs[formName].clearValidate();
    },
    onSubmit() {
      console.log("submit!");
    },
    handleClick(row, handle) {
      if (this.currentPageName === "作业区机关") {
        // 代表现在在作业区机关页面打开隐藏的form表单，应该显示作业区机关的Form
        this.zyqjgFormVisible = true;
        if (handle === "check") {
          // this.zyqjgForm = row;
          // this.myDialogTitle = "作业区机关信息查看";
          // this.ischeck = true;
          // this.$message({ message: "成功打开", type: "success" });
          this.myDialogTitle = "信息查看";
          if (row.approveStatus == 0) {
            this.ischeckSh = true;
          } else {
            this.ischeckSh = false;
          }
          this.ischeck = true;
          this.isInput = true; // 1.表单禁用
          // this.isAble = false;
          // this.syjForm = row
          this.$objCopy(row, this.zyqjgForm); //把当前要编辑的数据复制到数据域，给表单回显
          this.$message({ message: "成功打开", type: "success" });
        } else if (handle === "edit") {
          // this.zyqjgForm.unit = "作业区机关";
          // this.zyqjgForm = row;
          // this.myDialogTitle = "作业区机关信息编辑";
          // this.ischeck = false;
          // this.$message({ message: "编辑成功", type: "success" });
          this.isAble = true;
          if (row.approveStatus != 2) {
            this.myDialogTitle = "信息编辑";
            this.ischeck = false;
            this.ischeckSh = false;
            this.isInput = false;
            this.$objCopy(row, this.zyqjgForm); //把当前要编辑的数据复制到数据域，给表单回显
          } else {
            this.zyqjgFormVisible = false;
            this.$message({ message: "已通过不可修改！", type: "error" });
          }
        } else if (handle === "add") {
          // this.$resetForm("zyqjgForm", this.zyqjgForm); //清空表单数据
          // this.myDialogTitle = "作业区机关信息填报";
          // this.ischeck = false;
          // this.$message({ message: "添加成功", type: "success" });
          this.$resetForm("zyqjgForm", this.zyqjgForm); //清空表单数据
          this.myDialogTitle = "信息填报";
          this.ischeck = false;
          this.ischeckSh = false;
          this.isInput = false;
          this.isAble = false;
          //同时其他的Form设置为false
          this.d14dFormVisible = false;
          this.d16wsdFormVisible = false;
          this.d18dFormVisible = false;
          this.s382dFormVisible = false;
          this.d162dFormVisible = false;
          this.s371dFormVisible = false;
          this.yjqxdFormVisible = false;
          this.dgdFormVisible = false;
          this.stFormVisible = false;
        }
      } else if (this.currentPageName === "东14队") {
        // 代表现在在东14队页面打开隐藏的form表单，应该显示东14队的Form
        this.d14dFormVisible = true;
        if (handle === "check") {
          this.d14dForm = row;
          this.myDialogTitle = "东14队信息查看";
          this.ischeck = true;
          this.$message({ message: "成功打开", type: "success" });
        } else if (handle === "edit") {
          this.d14dForm = row;
          this.myDialogTitle = "东14队信息编辑";
          this.ischeck = false;
          this.$message({ message: "编辑成功", type: "success" });
        } else if (handle === "add") {
          this.$resetForm("d14dForm", this.d14dForm); //清空表单数据
          this.myDialogTitle = "东14队信息填报";
          this.ischeck = false;
          this.$message({ message: "添加成功", type: "success" });
        }
        this.zyqjgFormVisible = false;
        this.d16wsdFormVisible = false;
        this.d18dFormVisible = false;
        this.s382dFormVisible = false;
        this.d162dFormVisible = false;
        this.s371dFormVisible = false;
        this.yjqxdFormVisible = false;
        this.dgdFormVisible = false;
        this.stFormVisible = false;
      } else if (this.currentPageName === "东16污水队") {
        // 代表现在在东16污水队页面打开隐藏的form表单，应该显示东16污水队的Form
        this.d16wsdFormVisible = true;

        if (handle === "check") {
          this.d16wsdForm = row;
          this.myDialogTitle = "东16污水队信息查看";
          this.ischeck = true;
          this.$message({ message: "成功打开", type: "success" });
        } else if (handle === "edit") {
          this.d16wsdForm = row;
          this.myDialogTitle = "东16污水队信息编辑";
          this.ischeck = false;
          this.$message({ message: "编辑成功", type: "success" });
        } else if (handle === "add") {
          this.$resetForm("d16wsdForm", this.d16wsdForm); //清空表单数据
          this.myDialogTitle = "东16污水队信息填报";
          this.ischeck = false;
          this.$message({ message: "添加成功", type: "success" });
        }
        this.zyqjgFormVisible = false;
        this.d14dFormVisible = false;
        this.d18dFormVisible = false;
        this.s382dFormVisible = false;
        this.d162dFormVisible = false;
        this.s371dFormVisible = false;
        this.yjqxdFormVisible = false;
        this.dgdFormVisible = false;
        this.stFormVisible = false;
      } else if (this.currentPageName === "东18队") {
        // 代表现在在东18队页面打开隐藏的form表单，应该显示东18队的Form
        this.d18dFormVisible = true;

        if (handle === "check") {
          this.d18dForm = row;
          this.myDialogTitle = "东18队信息查看";
          this.ischeck = true;
          this.$message({ message: "成功打开", type: "success" });
        } else if (handle === "edit") {
          this.d18dForm = row;
          this.myDialogTitle = "东18队信息编辑";
          this.ischeck = false;
          this.$message({ message: "编辑成功", type: "success" });
        } else if (handle === "add") {
          this.$resetForm("d18dForm", this.d18dForm); //清空表单数据
          this.myDialogTitle = "东18队信息填报";
          this.ischeck = false;
          this.$message({ message: "添加成功", type: "success" });
        }
        this.zyqjgFormVisible = false;
        this.d14dFormVisible = false;
        this.d16wsdFormVisible = false;
        this.s382dFormVisible = false;
        this.d162dFormVisible = false;
        this.s371dFormVisible = false;
        this.yjqxdFormVisible = false;
        this.dgdFormVisible = false;
        this.stFormVisible = false;
      } else if (this.currentPageName === "升382队") {
        // 代表现在在升382队页面打开隐藏的form表单，应该显示升382队的Form
        this.s382dFormVisible = true;

        if (handle === "check") {
          this.s382dForm = row;
          this.myDialogTitle = "升382队信息查看";
          this.ischeck = true;
          this.$message({ message: "成功打开", type: "success" });
        } else if (handle === "edit") {
          this.s382dForm = row;
          this.myDialogTitle = "升382队信息编辑";
          this.ischeck = false;
          this.$message({ message: "编辑成功", type: "success" });
        } else if (handle === "add") {
          this.$resetForm("s382dForm", this.s382dForm); //清空表单数据
          this.myDialogTitle = "升382队信息填报";
          this.ischeck = false;
          this.$message({ message: "添加成功", type: "success" });
        }
        this.zyqjgFormVisible = false;
        this.d14dFormVisible = false;
        this.d16wsdFormVisible = false;
        this.d18dFormVisible = false;
        this.d162dFormVisible = false;
        this.s371dFormVisible = false;
        this.yjqxdFormVisible = false;
        this.dgdFormVisible = false;
        this.stFormVisible = false;
      } else if (this.currentPageName === "东162队") {
        // 代表现在在东162队页面打开隐藏的form表单，应该显示东162队的Form
        this.d162dFormVisible = true;

        if (handle === "check") {
          this.d162dForm = row;
          this.myDialogTitle = "东162队信息查看";
          this.ischeck = true;
          this.$message({ message: "成功打开", type: "success" });
        } else if (handle === "edit") {
          this.d162dForm = row;
          this.myDialogTitle = "东162队信息编辑";
          this.ischeck = false;
          this.$message({ message: "编辑成功", type: "success" });
        } else if (handle === "add") {
          this.$resetForm("d162dForm", this.d162dForm); //清空表单数据
          this.myDialogTitle = "东162队信息填报";
          this.ischeck = false;
          this.$message({ message: "添加成功", type: "success" });
        }
        this.zyqjgFormVisible = false;
        this.d14dFormVisible = false;
        this.d16wsdFormVisible = false;
        this.d18dFormVisible = false;
        this.s382dFormVisible = false;
        this.s371dFormVisible = false;
        this.yjqxdFormVisible = false;
        this.dgdFormVisible = false;
        this.stFormVisible = false;
      } else if (this.currentPageName === "升371队") {
        // 代表现在在升371队页面打开隐藏的form表单，应该显示升371队的Form
        this.s371dFormVisible = true;

        if (handle === "check") {
          this.s371dForm = row;
          this.myDialogTitle = "升371队信息查看";
          this.ischeck = true;
          this.$message({ message: "成功打开", type: "success" });
        } else if (handle === "edit") {
          this.s371dForm = row;
          this.myDialogTitle = "升371队信息编辑";
          this.ischeck = false;
          this.$message({ message: "编辑成功", type: "success" });
        } else if (handle === "add") {
          this.$resetForm("s371dForm", this.s371dForm); //清空表单数据
          this.myDialogTitle = "升371队信息填报";
          this.ischeck = false;
          this.$message({ message: "添加成功", type: "success" });
        }
        this.zyqjgFormVisible = false;
        this.d14dFormVisible = false;
        this.d16wsdFormVisible = false;
        this.d18dFormVisible = false;
        this.s382dFormVisible = false;
        this.d162dFormVisible = false;
        this.yjqxdFormVisible = false;
        this.dgdFormVisible = false;
        this.stFormVisible = false;
      } else if (this.currentPageName === "应急抢险队") {
        // 代表现在在应急抢险队页面打开隐藏的form表单，应该显示应急抢险队的Form
        this.yjqxdFormVisible = true;

        if (handle === "check") {
          this.yjqxdForm = row;
          this.myDialogTitle = "应急抢险队信息查看";
          this.ischeck = true;
          this.$message({ message: "成功打开", type: "success" });
        } else if (handle === "edit") {
          this.yjqxdForm = row;
          this.myDialogTitle = "应急抢险队信息编辑";
          this.ischeck = false;
          this.$message({ message: "编辑成功", type: "success" });
        } else if (handle === "add") {
          this.$resetForm("yjqxdForm", this.yjqxdForm); //清空表单数据
          this.myDialogTitle = "应急抢险队信息填报";
          this.ischeck = false;
          this.$message({ message: "添加成功", type: "success" });
        }
        this.zyqjgFormVisible = false;
        this.d14dFormVisible = false;
        this.d16wsdFormVisible = false;
        this.d18dFormVisible = false;
        this.s382dFormVisible = false;
        this.d162dFormVisible = false;
        this.s371dFormVisible = false;
        this.dgdFormVisible = false;
        this.stFormVisible = false;
      } else if (this.currentPageName === "地工队") {
        // 代表现在在地工队页面打开隐藏的form表单，应该显示地工队的Form
        this.dgdFormVisible = true;

        if (handle === "check") {
          this.dgdForm = row;
          this.myDialogTitle = "地工队信息查看";
          this.ischeck = true;
          this.$message({ message: "成功打开", type: "success" });
        } else if (handle === "edit") {
          this.dgdForm = row;
          this.myDialogTitle = "地工队信息编辑";
          this.ischeck = false;
          this.$message({ message: "编辑成功", type: "success" });
        } else if (handle === "add") {
          this.$resetForm("dgdForm", this.dgdForm); //清空表单数据
          this.myDialogTitle = "地工队信息填报";
          this.ischeck = false;
          this.$message({ message: "添加成功", type: "success" });
        }
        this.zyqjgFormVisible = false;
        this.d14dFormVisible = false;
        this.d16wsdFormVisible = false;
        this.d18dFormVisible = false;
        this.s382dFormVisible = false;
        this.d162dFormVisible = false;
        this.s371dFormVisible = false;
        this.yjqxdFormVisible = false;
        this.stFormVisible = false;
      } else if (this.currentPageName === "食堂") {
        // 代表现在在食堂页面打开隐藏的form表单，应该显示食堂的Form
        this.stFormVisible = true;

        if (handle === "check") {
          this.stForm = row;
          this.myDialogTitle = "食堂信息查看";
          this.ischeck = true;
          this.$message({ message: "成功打开", type: "success" });
        } else if (handle === "edit") {
          this.stForm = row;
          this.myDialogTitle = "食堂信息编辑";
          this.ischeck = false;
          this.$message({ message: "编辑成功", type: "success" });
        } else if (handle === "add") {
          this.$resetForm("stForm", this.stForm); //清空表单数据
          this.myDialogTitle = "食堂信息填报";
          this.ischeck = false;
          this.$message({ message: "添加成功", type: "success" });
        }
        this.zyqjgFormVisible = false;
        this.d14dFormVisible = false;
        this.d16wsdFormVisible = false;
        this.d18dFormVisible = false;
        this.s382dFormVisible = false;
        this.d162dFormVisible = false;
        this.s371dFormVisible = false;
        this.yjqxdFormVisible = false;
        this.dgdFormVisible = false;
      }
    },
    uploadData() {
      console.log("批量导入成功");
    },

    //每页条数改变时触发 选择一页显示多少行
    handleSizeChange(val) {
      console.log(`每页 ${val} 条`);
      // this.pageNo = 1;
      this.pageSize = val;
      this.search();
      // this.search(this.pageNo, val);
    },
    //当前页改变时触发 跳转其他页
    handleCurrentChange(val) {
      console.log(`当前页: ${val}`);
      this.pageNo = val;
      this.search();
    },
    // 序号计算
    indexMethod(index) {
      // index默认在0开始，这里+1
      return index + 1 + (this.pageNo - 1) * this.pageSize;
    },

    //Tab标签区域切换按钮事件
    handleMenuClick(tab, event) {
      var content = event.target.innerText;
      if (content === "作业区机关") {
        this.currentPageName = "作业区机关";
        this.search();
        this.zyqjgVisable = true;
        this.d14dVisable = false;
        this.d16wsdVisable = false;
        this.d18dVisable = false;
        this.s382dVisable = false;
        this.d162dVisable = false;
        this.s371dVisable = false;
        this.yjqxdVisable = false;
        this.dgdVisable = false;
        this.stVisable = false;
      } else if (content === "东14队") {
        this.currentPageName = "东14队";
        this.search();
        this.zyqjgVisable = false;
        this.d14dVisable = true;
        this.d16wsdVisable = false;
        this.d18dVisable = false;
        this.s382dVisable = false;
        this.d162dVisable = false;
        this.s371dVisable = false;
        this.yjqxdVisable = false;
        this.dgdVisable = false;
        this.stVisable = false;
      } else if (content === "东16污水队") {
        this.currentPageName = "东16污水队";
        this.search();
        this.zyqjgVisable = false;
        this.d14dVisable = false;
        this.d16wsdVisable = true;
        this.d18dVisable = false;
        this.s382dVisable = false;
        this.d162dVisable = false;
        this.s371dVisable = false;
        this.yjqxdVisable = false;
        this.dgdVisable = false;
        this.stVisable = false;
      } else if (content === "东18队") {
        this.currentPageName = "东18队";
        this.search();
        this.zyqjgVisable = false;
        this.d14dVisale = false;
        this.d16wsdVisable = false;
        this.d18dVisable = true;
        this.s382dVisable = false;
        this.d162dVisable = false;
        this.s371dVisable = false;
        this.yjqxdVisable = false;
        this.dgdVisable = false;
        this.stVisable = false;
      } else if (content === "升382队") {
        this.currentPageName = "升382队";
        this.search();
        this.zyqjgVisable = false;
        this.d14dVisable = false;
        this.d16wsdVisable = false;
        this.d18dVisable = false;
        this.s382dVisable = true;
        this.d162dVisable = false;
        this.s371dVisable = false;
        this.yjqxdVisable = false;
        this.dgdVisable = false;
        this.stVisable = false;
      } else if (content === "东162队") {
        this.currentPageName = "东162队";
        this.search();
        this.zyqjgVisable = false;
        this.d14dVisable = false;
        this.d16wsdVisable = false;
        this.d18dVisable = false;
        this.s382dVisable = false;
        this.d162dVisable = true;
        this.s371dVisable = false;
        this.yjqxdVisable = false;
        this.dgdVisable = false;
        this.stVisable = false;
      } else if (content === "升371队") {
        this.currentPageName = "升371队";
        this.search();
        this.zyqjgVisable = false;
        this.d14dVisable = false;
        this.d16wsdVisable = false;
        this.d18dVisable = false;
        this.s382dVisable = false;
        this.d162dVisable = false;
        this.s371dVisable = true;
        this.yjqxdVisable = false;
        this.dgdVisable = false;
        this.stVisable = false;
      } else if (content === "应急抢险队") {
        this.currentPageName = "应急抢险队";
        this.search();
        this.zyqjgVisable = false;
        this.d14dVisable = false;
        this.d16wsdVisable = false;
        this.d18dVisable = false;
        this.s382dVisable = false;
        this.d162dVisable = false;
        this.s371dVisable = false;
        this.yjqxdVisable = true;
        this.dgdVisable = false;
        this.stVisable = false;
      } else if (content === "地工队") {
        this.currentPageName = "地工队";
        this.search();
        this.zyqjgVisable = false;
        this.d14dVisable = false;
        this.d16wsdVisable = false;
        this.d18dVisable = false;
        this.s382dVisable = false;
        this.d162dVisable = false;
        this.s371dVisable = false;
        this.yjqxdVisable = false;
        this.dgdVisable = true;
        this.stVisable = false;
      } else {
        this.currentPageName = "食堂";
        this.search();
        this.zyqjgVisable = false;
        this.d14dVisable = false;
        this.d16wsdVisable = false;
        this.d18dVisable = false;
        this.s382dVisable = false;
        this.d162dVisable = false;
        this.s371dVisable = false;
        this.yjqxdVisable = false;
        this.dgdVisable = false;
        this.stVisable = true;
      }
      console.log(this.currentPageName);
    },
    // close() {
    //   //作业区机关编辑框是否显示
    //   this.zyqjgFormVisible = false;
    //   //东14队编辑框是否显示
    //   this.d14dFormVisible = false;
    //   //东16污水队编辑框是否显示
    //   this.d16wsdFormVisible = false;
    //   //东18队编辑框是否显示
    //   this.d18dFormVisible = false;
    //   //升382队编辑框是否显示
    //   this.s382dFormVisible = false;
    //   //东162队编辑框是否显示
    //   this.d162dFormVisible = false;
    //   //升371队编辑框是否显示
    //   this.s371dFormVisible = false;
    //   //应急抢险队编辑框是否显示
    //   this.yjqxdFormVisible = false;
    //   //地工队编辑框是否显示
    //   this.dgdFormVisible = false;
    //   //食堂编辑框是否显示
    //   this.stFormVisible = false;
    //   this.search();
    // },
    submitForm(formName) {
      //表单验证
      this.$refs[formName].validate(async (valid) => {
        if (valid) {
          let res = null;
          console.log("this.zyqjgForm.id", this.zyqjgForm.id);
          //判断菜单ID是否为空,则说明是添加
          if (
            typeof this.zyqjgForm.id != "undefined" &&
            this.zyqjgForm.id != 0
          ) {
            console.log("zyqjgForm", this.zyqjgForm);
            //发送修改请求
            this.zyqjgForm.approveStatus = 0;
            // console.log(334345)
            res = await xfqctzApi.updateXfqctz(this.zyqjgForm);
          } else {
            this.zyqjgForm.rq = moment().format("YYYY-MM-DD");
            //发送添加请求
            console.log("zyqjgForm", this.zyqjgForm);
            res = await xfqctzApi.addXfqctz(this.zyqjgForm);
            console.log("res", res);
          }
          console.log(res);
          //判断是否成功
          if (res.success) {
            this.$message.success(res.message);
            //刷新
            this.search();
            //关闭窗口
            this.zyqjgFormVisible = false;
          } else {
            console.log(res);
            this.$message.error(res.message);
          }
        }
      });
    },
    async submitSh(formName) {
      let res = null;
      //发送修改请求
      this.zyqjgForm.approveStatus = 1;
      this.zyqjgrm.approveBz = "";
      // console.log(334345)
      res = await xfqctzApi.updateXfqctz(this.zyqjgForm);

      console.log(res);
      //判断是否成功
      if (res.success) {
        this.$message.success(res.message);
        //刷新
        this.search();
        //关闭窗口
        this.dialogFormVisible = false;
      } else {
        console.log(res);
        this.$message.error(res.message);
      }
    },
    uploadFiles() {
      this.importDialog = true;
      this.urlFile = "";
    },
    cancelUpload() {
      this.urlFile = "";
      this.fileList = [];
      this.importDialog = false;
    },
    //  监听改变
    handleChange(file, fileList) {
      this.fileList = fileList;
    },
    // 移除
    handleRemove(file, fileList) {
      this.fileList = fileList;
    },
    beforeAvatarUpload(file) {
      //1MB=1024*1024(1MB=1024KB 1KB=1024MB)
      const is10M = file.size / 1024 / 1024 < 10;
      //限制文件上传大小
      if (!is10M) {
        this.$message.error("上传图片大小不能超过 10MB!");
        return false;
      }
      return true;
    },
    //上传成功之后清除历史记录
    // handleSuccess(fileList) {
    //   this.fileList = [];
    //   this.$refs['fileForm'].upload.clearFiles()
    // },
    // 自定义上传Excel方法
    httpRequest(param) {
      // console.log(param.file);
      this.uploading = true;
      const File = this.fileList[0].raw;
      // const File = param.file
      console.log(File);
      // console.log(this.fileList);
      let formData = new FormData();
      formData.append("myfile", File);
      console.log(formData.get("myfile"));

      axios({
        url: "http://47.108.251.250:3296/api/fileAbout/fileUpload",
        method: "post",
        headers: {
          token: getToken(),
          "Content-Type": "multipart/form-data",
        },
        data: formData,
      }).then(
        (response) => {
          if (response.data.success === true && response.data.data !== "") {
            console.log(response.data);
            this.urlFile = response.data.data;
            console.log(this.urlFile);
            this.$message.success(response.data.message);
            param.onSuccess();
            this.uploading = false;
          } else {
            this.$message.error("上传失败");
          }
        },
        (error) => {
          console.log(error);
          this.$message.error(response.data.message);
        }
      );
    },
    //文件导入
    upload() {
      let formData = new FormData();
      formData.append("filePath", this.urlFile);
      console.log(formData.get("filePath"));
      axios({
        url: "http://47.108.251.250:3296/api/xfqctz/batchInput",
        method: "post",
        headers: {
          token: getToken(),
          "Content-Type": "multipart/form-data",
        },
        data: formData,
      }).then(
        (response) => {
          if (response.data.success === true) {
            console.log(response.data);
            this.$message.success(response.data.message);
            //刷新
            this.search();
            //关闭窗口
            this.importDialog = false;
            this.fileList = [];
          } else {
            this.$message.error("导入失败");
          }
        },
        (error) => {
          console.log(error);
          this.$message.error(response.data.message);
        }
      );
    },
  },
  watch: {
    activeName(val) {
      if (this.activeName == "first") {
        this.unit = "作业区机关";
        this.search();
      } else if (this.activeName == "second") {
        this.unit = "东14队";
        this.search();
        // this.submitForm();
      } else if (this.activeName == "third") {
        this.unit = "东16污水队";
        this.search();
      } else if (this.activeName == "fourth") {
        this.unit = "东18队";
        this.search();
      } else if (this.activeName == "fifth") {
        this.unit = "升382队";
        this.search();
      } else if (this.activeName == "sixth") {
        this.unit = "东162队";
        this.search();
      } else if (this.activeName == "seventh") {
        this.unit = "升371队";
        this.search();
      } else if (this.activeName == "eighth") {
        this.unit = "应急抢险队";
        this.search();
      } else if (this.activeName == "ninth") {
        this.unit = "地工队";
        this.search();
      } else if (this.activeName == "tenth") {
        this.unit = "食堂";
        this.search();
      }
    },
  },
};
</script>

<style lang="scss" scoped>
// 标题
.mytitle {
  font-size: large;
  padding-left: 10px;
  margin-bottom: 16px;
  float: left;
}

//按钮组
.myButtons {
  float: right;
}

//格子的样式
.bg-white {
  background: #ffffff;
}

.grid-content {
  padding: 10px;
  margin-bottom: 10px;
  border-radius: 4px;
}

.calendar ::v-deep .el-button-group::before {
  display: none;
}

.calendar ::v-deep .el-button-group::after {
  display: none;
}

// 分割线样式
.el-divider--horizontal {
  display: block;
  height: 2px;
  width: 100%;
  margin: 24px 0;
}

// 表单各项的样式
.el-form-item {
  margin: 15px 10px 15px 10px;
}
</style>
